time: 2021.3
# -*- coding: utf-8 -*-
# @Time    : 2021/4/22 19:32
# @Author  : luogan
# @Email   : 468640092@qq.com
# @File    : 爬虫.py
# @Software: PyCharm.

import requests
import re
url="https://www.sanchuangedu.cn/"
respond = requests.get(url)
html = respond.text
url1 = re.findall('<img.*src="(.*?)".*', html)
print(url1)
url2 = url + url1[0]
print(url2)
s=requests.get(url2)
with open("dc.jpg","wb") as fp:
	fp.write(s.content)
print("下载成功")